/**
 * @description 这个接口应该是全局都是用一个对象，因为全局使用这里的数据，都是一个数据，应该导出一个实例对象
 */

// 定义一个用户服务类
class MockService {
    typesList = {
        "types_list":[
            // 推荐
            {
                "image":"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/5f9b64b5e35f833a589d20dec77a25b6.png?w=734&h=220&bg=7F0000",
                "type": "推荐",
                "title_list":[
                    {
                        "title":"精选推荐",
                        "category_list":[
                            {name:"Redmi K50 Pro",price:"2999",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/bfe68c63caca6622d1673efa7d7e7a7d.png?w=800&h=800",},
                            {name:"Xiaomi 11 Ultra",price:"3999",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/cea1ff3517387569b7f59fc2b7d01d30.png?w=800&h=800"},
                            {name:"Redmi K50",price:"2399",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/268eb39e48af6bb86e448e143a119eea.png?w=800&h=800"},
                            {name:"小米手环6",price:"199",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/454c948d5b24aa50153010e0488c28e0.png?w=800&h=800"},
                            {name:"米家指甲刀五件套",price:"39.9",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/fec3b5c6f4377397621e2d6c51b6e455.png?w=800&h=800"},
                            {name:"WiFi放大器",price:"69",img:"https://cdn.cnbj0.fds.api.mi-img.com/b2c-mimall-media/a3ce2e5766e231d75fa15d7934b493fd.png?w=800&h=800",},
                            {name:"米家台灯Lite",price:"79",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/3f67b2ce4d1316f6adc399ad158dc157.png?w=800&h=800",},
                        ]
                    },
                ],
            },
            // 第一条
            {
                "image":"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/e36936363beac0fa5bb10078944607b2.png?w=734&h=220&bg=7F0000",
                "type":"Xiaomi手机",
                "title_list":[
                    {
                        "title":"Xiaomi Civi",
                        "category_list":[
                            {"name":"Xiaomi Civi","price":"2299","img":"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/2fb0f98dd723b9a3b66167aa7e86a8ea.png?w=800&h=800"},
                        ]
                    },
                    {
                        "title":"Xiaomi 数字系列",
                        "category_list":[
                            {name:"Xiaomi 12 Pro",price:"4699",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/bec639601906ed7649970c6ab311f992.png?w=800&h=800",},
                            {name:"Xiaomi 12",price:"3699",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/eac4850d9dbc5305b1298b8c1c686c17.png?w=800&h=800",},
                            {name:"Xiaomi 12X",price:"3199",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/349cdb45e012cd89e2efa3962a991b84.png?w=800&h=800",},
                            {name:"Xiaomi 11 青春活力版",price:"1999",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/0593c1e9e06a125b9e22c1041aa0a85d.png?w=800&h=800",},
                            {name:"Xiaomi 11 UItra",price:"5499",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/cea1ff3517387569b7f59fc2b7d01d30.png?w=800&h=800",},
                            {name:"Xiaomi 11 Pro",price:"3369",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/2237d83d46b43a7dca0b5fb6db2a9700.png?w=800&h=800",},
                            {name:"Xiaomi 11 青春版",price:"1999",img:"	https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/b0e55e428c57a718fd87d23cce939637.png?w=800&h=800",},
                            {name:"Xiaomi 10S",price:"2399",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/9732a817c834a5002e3ee5b7947e00ec.png?w=800&h=800",},
                            {name:"Xiaomi 11",price:"2999",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/9732a817c834a5002e3ee5b7947e00ec.png?w=800&h=800",},
                            {name:"Xiaomi 10 青春版 5G",price:"1899",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/58a4446432aba7894e957f2c18853562.png?w=800&h=800",},
                        ]
                    },
                    {
                        "title":"Xiaomi MIX系列",
                        "category_list":[
                            {name:"Xiaomi MIX 4",price:"4199",img:"	https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/b127cc0b8ace12de00bbb6b55613e266.png?w=800&h=800"},
                            {name:"Xiaomi MIX FOLD折叠屏",price:"6999",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/bdce853ddf592e9965d7ea807cc124c8.png?w=800&h=800"},
                            {name:"Xiaomi MIX Alpha",price:"19999",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/0c4b5e30d14ca8b51dc6fa6917295ff5.png?w=800&h=800"},
                        ]
                    },
                    {
                        "title":"手机配件",
                        "category_list":[
                            {name:"无线充",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/b127cc0b8ace12de00bbb6b55613e266.png?w=800&h=800"},
                            {name:"充电器",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/bdce853ddf592e9965d7ea807cc124c8.png?w=800&h=800"},
                            {name:"数据线",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/0c4b5e30d14ca8b51dc6fa6917295ff5.png?w=800&h=800"},
                        ],
                        "name":["无线充","充电器","数据线","充电宝","手机保护壳","手机贴膜","自拍杆"]
                    }
                ],
            },
            // 第二条
            {
                "image":"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/881986cc3292f2537287d97b63df6187.png?w=734&h=220&bg=7F0000",
                "type":"Redmi手机",
                "title_list":[
                    {
                        "title":"NOte系列",
                        "category_list":[
                            {name:"Xiaomi 12 Pro",price:"4699",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/bec639601906ed7649970c6ab311f992.png?w=800&h=800",},
                            {name:"Xiaomi 12",price:"3699",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/eac4850d9dbc5305b1298b8c1c686c17.png?w=800&h=800",},
                            {name:"Xiaomi 12X",price:"3199",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/349cdb45e012cd89e2efa3962a991b84.png?w=800&h=800",},
                            {"name":"Xiaomi Civi","price":"2299","img":"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/2fb0f98dd723b9a3b66167aa7e86a8ea.png?w=800&h=800"},
                        ]
                    },
                    {
                        "title":"K系列",
                        "category_list":[
                            {name:"Xiaomi 11 青春活力版",price:"1999",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/0593c1e9e06a125b9e22c1041aa0a85d.png?w=800&h=800",},
                            {name:"Xiaomi 11 UItra",price:"5499",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/cea1ff3517387569b7f59fc2b7d01d30.png?w=800&h=800",},
                            {name:"Xiaomi 11 Pro",price:"3369",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/2237d83d46b43a7dca0b5fb6db2a9700.png?w=800&h=800",},
                            {name:"Xiaomi 11 青春版",price:"1999",img:"	https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/b0e55e428c57a718fd87d23cce939637.png?w=800&h=800",},
                            {name:"Xiaomi 10S",price:"2399",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/9732a817c834a5002e3ee5b7947e00ec.png?w=800&h=800",},
                            {name:"Xiaomi 11",price:"2999",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/9732a817c834a5002e3ee5b7947e00ec.png?w=800&h=800",},
                            {name:"Xiaomi 10 青春版 5G",price:"1899",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/58a4446432aba7894e957f2c18853562.png?w=800&h=800",},
                        ]
                    },
                    {
                        "title":"数字系列",
                        "category_list":[
                            {name:"Xiaomi MIX 4",price:"4199",img:"	https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/b127cc0b8ace12de00bbb6b55613e266.png?w=800&h=800"},
                            {name:"Xiaomi MIX FOLD折叠屏",price:"6999",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/bdce853ddf592e9965d7ea807cc124c8.png?w=800&h=800"},
                            {name:"Xiaomi MIX Alpha",price:"19999",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/0c4b5e30d14ca8b51dc6fa6917295ff5.png?w=800&h=800"},
                        ]
                    },
                    {
                        "title":"Redmi手机配件",
                        "name":["无线充","充电器","数据线","充电宝","手机保护壳","手机贴膜","自拍杆"]
                    }
                ],
            },
            {
                "image":"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/d9d323c5fb9e8fefb60b85fb1f6ae7b2.png?w=734&h=220&bg=FF",
                "type":"游戏手机",
                "title_list":[
                    {
                        "title":"游戏手机",
                        "category_list":[
                            {name:"Xiaomi 12 Pro",price:"4699",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/bec639601906ed7649970c6ab311f992.png?w=800&h=800",},
                            {name:"Xiaomi 12",price:"3699",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/eac4850d9dbc5305b1298b8c1c686c17.png?w=800&h=800",},
                            {name:"Xiaomi 12X",price:"3199",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/349cdb45e012cd89e2efa3962a991b84.png?w=800&h=800",},
                            {name:"Xiaomi 11 青春活力版",price:"1999",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/0593c1e9e06a125b9e22c1041aa0a85d.png?w=800&h=800",},
                            {name:"Xiaomi 11 UItra",price:"5499",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/cea1ff3517387569b7f59fc2b7d01d30.png?w=800&h=800",},
                            {name:"Xiaomi 11 Pro",price:"3369",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/2237d83d46b43a7dca0b5fb6db2a9700.png?w=800&h=800",},
                            {name:"Xiaomi 11 青春版",price:"1999",img:"	https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/b0e55e428c57a718fd87d23cce939637.png?w=800&h=800",},
                            {name:"Xiaomi 10S",price:"2399",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/9732a817c834a5002e3ee5b7947e00ec.png?w=800&h=800",},
                            {name:"Xiaomi 11",price:"2999",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/9732a817c834a5002e3ee5b7947e00ec.png?w=800&h=800",},
                            {name:"Xiaomi 10 青春版 5G",price:"1899",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/58a4446432aba7894e957f2c18853562.png?w=800&h=800",},
                        ]
                    },
                    {
                        "title":"游戏手机配件",
                        "name":["无线充","充电器","数据线","充电宝","手机保护壳","手机贴膜","自拍杆"]
                    }
                ],
            },
            {
                "image":"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/e0ef40c401779d31b218fe2c35d155f6.png?w=734&h=220&bg=7F0000",
                "type":"电脑平板",
                "title_list":[
                    {
                        "title":"电脑平板",
                        "category_list":[
                            {name:"Xiaomi 12 Pro",price:"4699",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/bec639601906ed7649970c6ab311f992.png?w=800&h=800",},
                            {name:"Xiaomi 12",price:"3699",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/eac4850d9dbc5305b1298b8c1c686c17.png?w=800&h=800",},
                            {name:"Xiaomi 12X",price:"3199",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/349cdb45e012cd89e2efa3962a991b84.png?w=800&h=800",},
                            {name:"Xiaomi 11 青春活力版",price:"1999",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/0593c1e9e06a125b9e22c1041aa0a85d.png?w=800&h=800",},
                            {name:"Xiaomi 11 UItra",price:"5499",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/cea1ff3517387569b7f59fc2b7d01d30.png?w=800&h=800",},
                            {name:"Xiaomi 11 Pro",price:"3369",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/2237d83d46b43a7dca0b5fb6db2a9700.png?w=800&h=800",},
                            {name:"Xiaomi 11 青春版",price:"1999",img:"	https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/b0e55e428c57a718fd87d23cce939637.png?w=800&h=800",},
                            {name:"Xiaomi 10S",price:"2399",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/9732a817c834a5002e3ee5b7947e00ec.png?w=800&h=800",},
                            {name:"Xiaomi 11",price:"2999",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/9732a817c834a5002e3ee5b7947e00ec.png?w=800&h=800",},
                            {name:"Xiaomi 10 青春版 5G",price:"1899",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/58a4446432aba7894e957f2c18853562.png?w=800&h=800",},
                        ]
                    },
                    {
                        "title":"游戏手机配件",
                        "name":["无线充","充电器","数据线","充电宝","手机保护壳","手机贴膜","自拍杆"]
                    }
                ],
            },
            {
                "image":"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/45347c0635c3d40c3174cda1230af477.png?w=734&h=220&bg=7F0000",
                "type": "智能穿戴",
                "title_list":[
                    {
                        "title":"智能穿戴",
                        "category_list":[
                            {name:"Xiaomi 12 Pro",price:"4699",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/bec639601906ed7649970c6ab311f992.png?w=800&h=800",},
                            {name:"Xiaomi 12",price:"3699",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/eac4850d9dbc5305b1298b8c1c686c17.png?w=800&h=800",},
                            {name:"Xiaomi 12X",price:"3199",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/349cdb45e012cd89e2efa3962a991b84.png?w=800&h=800",},
                            {name:"Xiaomi 11 青春活力版",price:"1999",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/0593c1e9e06a125b9e22c1041aa0a85d.png?w=800&h=800",},
                            {name:"Xiaomi 11 UItra",price:"5499",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/cea1ff3517387569b7f59fc2b7d01d30.png?w=800&h=800",},
                            {name:"Xiaomi 11 Pro",price:"3369",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/2237d83d46b43a7dca0b5fb6db2a9700.png?w=800&h=800",},
                            {name:"Xiaomi 11 青春版",price:"1999",img:"	https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/b0e55e428c57a718fd87d23cce939637.png?w=800&h=800",},
                            {name:"Xiaomi 10S",price:"2399",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/9732a817c834a5002e3ee5b7947e00ec.png?w=800&h=800",},
                            {name:"Xiaomi 11",price:"2999",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/9732a817c834a5002e3ee5b7947e00ec.png?w=800&h=800",},
                            {name:"Xiaomi 10 青春版 5G",price:"1899",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/58a4446432aba7894e957f2c18853562.png?w=800&h=800",},
                        ]
                    },
                    {
                        "title":"游戏手机配件",
                        "name":["无线充","充电器","数据线","充电宝","手机保护壳","手机贴膜","自拍杆"]
                    }
                ],
            },
            {
                "image":"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/5994c1adce81158f9dd14f4cfbd99e8e.png?w=734&h=220&bg=B2",
                "type":"电视",
                "title_list":[
                    {
                        "title":"电视",
                        "category_list":[
                            {name:"Xiaomi 12 Pro",price:"4699",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/bec639601906ed7649970c6ab311f992.png?w=800&h=800",},
                            {name:"Xiaomi 12",price:"3699",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/eac4850d9dbc5305b1298b8c1c686c17.png?w=800&h=800",},
                            {name:"Xiaomi 12X",price:"3199",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/349cdb45e012cd89e2efa3962a991b84.png?w=800&h=800",},
                            {name:"Xiaomi 11 青春活力版",price:"1999",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/0593c1e9e06a125b9e22c1041aa0a85d.png?w=800&h=800",},
                            {name:"Xiaomi 11 UItra",price:"5499",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/cea1ff3517387569b7f59fc2b7d01d30.png?w=800&h=800",},
                            {name:"Xiaomi 11 Pro",price:"3369",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/2237d83d46b43a7dca0b5fb6db2a9700.png?w=800&h=800",},
                            {name:"Xiaomi 11 青春版",price:"1999",img:"	https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/b0e55e428c57a718fd87d23cce939637.png?w=800&h=800",},
                            {name:"Xiaomi 10S",price:"2399",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/9732a817c834a5002e3ee5b7947e00ec.png?w=800&h=800",},
                            {name:"Xiaomi 11",price:"2999",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/9732a817c834a5002e3ee5b7947e00ec.png?w=800&h=800",},
                            {name:"Xiaomi 10 青春版 5G",price:"1899",img:"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/58a4446432aba7894e957f2c18853562.png?w=800&h=800",},
                        ]
                    },
                    {
                        "title":"游戏手机配件",
                        "name":["无线充","充电器","数据线","充电宝","手机保护壳","手机贴膜","自拍杆"]
                    }
                ],
            },
            {
                "image":"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/e36936363beac0fa5bb10078944607b2.png?w=734&h=220&bg=7F0000",
                "type":"大家电",
            },
            {
                "image":"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/e36936363beac0fa5bb10078944607b2.png?w=734&h=220&bg=7F0000",
                "type":"小家电",
            },
            {
                "image":"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/e36936363beac0fa5bb10078944607b2.png?w=734&h=220&bg=7F0000",
                "type":"智能家居",
            },
            {
                "image":"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/e36936363beac0fa5bb10078944607b2.png?w=734&h=220&bg=7F0000",
                "type":"户外出行",
            },
            {
                "image":"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/e36936363beac0fa5bb10078944607b2.png?w=734&h=220&bg=7F0000",
                "type":"日用百货",
            },
            {
                "image":"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/e36936363beac0fa5bb10078944607b2.png?w=734&h=220&bg=7F0000",
                "type":"儿童用品",
            },
            {
                "image":"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/e36936363beac0fa5bb10078944607b2.png?w=734&h=220&bg=7F0000",
                "type": "有选精品",
            },
            {
                "image":"https://cdn.cnbj1.fds.api.mi-img.com/mi-mall/e36936363beac0fa5bb10078944607b2.png?w=734&h=220&bg=7F0000",
                "type": "小米服务",
            },
         ],   
        
    }

    // 获取分类数据方法
    gettypesListApi() {
        return new Promise(resolve => {
            // 截取UserList中的数据进行返回
            let _result = this.typesList
            resolve({
                code: 200,
                data: {rows: _result, total: this.typesList.length}
            })
        })
    }


}

// 导出实例对象
export default new MockService()










